﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _05月17日作业
{
    class Program

    {
        public string Id { get; set; }
        public string Name { get; set; }
        public char Sex { get; set; }
        public string Cardid { get; set; }
        public string Tel { get; set; }
        //（Id）、姓名（Name）、性别（Sex）、身份证号（Cardid）、联系方式（Tel）、专业（Major）、年级（Grade）

        //（Id）、姓名（Name）,性别 （Sex）、身份证号（Cardid）、联系方式（Tel）、职称（Title）、工资号（Wageno）
        public Program(string Id, string Name, char Sex, string Cardid, string Tel)
        {
            this.Id = Id;
            this.Name = Name;
            this.Sex = Sex;
            this.Cardid = Cardid;
            this.Tel = Tel;
        }
        class Teacher : Program
        {
            public string Title { get; set; }
            public string Wageno { get; set; }

            public Teacher(string Id, string Name, char Sex, string Cardid, string Tel) : base(Id, Name, Sex, Cardid, Tel)
            {

            }
            public Teacher(string Id, string Name, char Sex, string Cardid, string Tel, string Title, string Wageno) : base(Id, Name, Sex, Cardid, Tel)
            {
                this.Title = Title;
                this.Wageno = Wageno;
            }
            public void print()
            {
                Console.WriteLine("我的教师编号是：{0}，我叫{1}，{2}，身份证号码是：{3}。", this.Id, this.Name, this.Sex, this.Cardid);
                Console.WriteLine("联系方式是：{0}，职称是：{1}，工资号是：{2}。", this.Tel, this.Title, this.Wageno);
            }
        }
        class Student : Program
        {
            public string Major { get; set; }
            public string Grade { get; set; }

            public Student(string Id, string Name, char Sex, string Cardid, string Tel) : base(Id, Name, Sex, Cardid, Tel)
            {

            }
            public Student(string Id, string Name, char Sex, string Cardid, string Tel, string Major, string Grade) : base(Id, Name, Sex, Cardid, Tel)
            {
                this.Major = Major;
                this.Grade = Grade;
            }
            public  void print()
            {
                Console.WriteLine("我的学生编号是：{0}，我叫{1}，{2}，身份证号码是：{3}。", this.Id, this.Name, this.Sex, this.Cardid);
                Console.WriteLine("联系方式是：{0}，{1}专业{2}。", this.Tel, this.Major, this.Grade);
            }

        }
        static void Main(string[] args)
        {
           
        }
    }
}
